import { ref } from 'vue'
/**
 * 首页金刚位列表
 */
export const diamondList = [
  {
    id: 10000025,
    title: '整租',
    key: 'whole_rent',
    iconPath:
      'https://bitejiaoyan.oss-cn-chengdu.aliyuncs.com/bitehouse/web/home/zhengzu.png'
  },
  {
    id: 10000026,
    title: '合租',
    key: 'share_rent',
    iconPath:
      'https://bitejiaoyan.oss-cn-chengdu.aliyuncs.com/bitehouse/web/home/hezu.png'
  },
  {
    id: 10000027,
    title: '省心租',
    key: 'worry_free_rental',
    iconPath:
      'https://bitejiaoyan.oss-cn-chengdu.aliyuncs.com/bitehouse/web/home/shengxinzu.png'
  },
  {
    id: 10000028,
    title: '公寓',
    key: 'apartment',
    iconPath:
      'https://bitejiaoyan.oss-cn-chengdu.aliyuncs.com/bitehouse/web/home/gongyu.png'
  },
  {
    id: 10000029,
    title: '个人房源',
    key: 'personal_house',
    iconPath:
      'https://bitejiaoyan.oss-cn-chengdu.aliyuncs.com/bitehouse/web/home/gerenfangyuan.png'
  }
]

/**
 * 筛选类型映射
 */
export const filterTypeMap = {
  // 区域
  region: 'region',
  // 租金
  price: 'price',
  // 户型
  houseType: 'houseType',
  // 排序
  sort: 'sort'
}

/**
 * 筛选类型列表
 */
export const filterTypeList = ref([
  {
    id: 1100001,
    // 筛选项的名称
    title: '区域',
    // 筛选类型
    type: filterTypeMap.region,
    // 筛选面板是否打开
    isOpen: false
  },
  {
    id: 1100002,
    title: '租金',
    type: filterTypeMap.price,
    isOpen: false
  },
  {
    id: 1100003,
    title: '户型',
    type: filterTypeMap.houseType,
    isOpen: false
  },
  {
    id: 1100004,
    title: '排序',
    type: filterTypeMap.sort,
    isOpen: false
  }
])

/**
 * 排序筛选下拉列表
 */
export const sortPullList = [
  {
    title: '距离优先',
    key: 'distance'
  },
  {
    title: '价格从低到高',
    key: 'price_asc'
  },
  {
    title: '价格从高到低',
    key: 'price_desc'
  }
]
